/**
 * @fileOverview Save plugin for inDynamic.
 */
(function() {
   var saveCmd = { modes:{wysiwyg:1,source:1 },
      readOnly: 1,

      exec: function( editor ) {
         Page.fireEvent( 'pressCtrlS' );
      }
   };

   VED.plugins.add( 'indysave', {
      init: function( editor ) {
         // inDySave plugin is for replace mode only.
         if ( editor.elementMode != VED.ELEMENT_MODE_REPLACE )
            return;

         var command = editor.addCommand( 'indysave', saveCmd );
         command.modes = { wysiwyg: !!( editor.element.$.form ) };
         
         editor.setKeystroke( VED.CTRL + 83 /*S*/, 'indysave' );
      }
   });
})();






